﻿using System.Windows.Media;
using KinonekoSoftware.Foundation.Patterns;

namespace KinonekoSoftware.Studio.Models
{
    public class StyledItem<T> : ObservableObject
    {
        private T      _value;
        private string _name;
        private string _intro;
        private Brush  _brush;
        private string _portrait;

        public string Portrait
        {
            get => _portrait;
            set => SetValue(ref _portrait, value);
        }

        /// <summary>
        /// 获取或设置 <see cref="Brush"/> 属性。
        /// </summary>
        public Brush Brush
        {
            get => _brush;
            set => SetValue(ref _brush, value);
        }

        /// <summary>
        /// 获取或设置 <see cref="Intro"/> 属性。
        /// </summary>
        public string Intro
        {
            get => _intro;
            set => SetValue(ref _intro, value);
        }
        
        /// <summary>
        /// 获取或设置 <see cref="Name"/> 属性。
        /// </summary>
        public string Name
        {
            get => _name;
            set => SetValue(ref _name, value);
        }

        /// <summary>
        /// 获取或设置 <see cref="Value"/> 属性。
        /// </summary>
        public T Value
        {
            get => _value;
            set => SetValue(ref _value, value);
        }
    }

    public sealed class StyledStringItem : StyledItem<string>
    {
    }

    public sealed class StyledBooleanItem : StyledItem<bool>
    {
    }

    public sealed class StyledNumericItem : StyledItem<int>
    {
        public int Maximum { get; set; }

    }
}